-
Notifications
You must be signed in to change notification settings - Fork 293
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Make tree_data static functions available in api #2101
Make tree_data static functions available in api #2101
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess I am fine with this but I am not sure making the functions inline has any benefit, I would think the compilers are smart enough to do it themselves as needed. So you may simply change them into normal functions.
Thanks Michal, I will do that then. |
8bdcf26
to
4a7f195
Compare
We need certain functions to be exposed via a public API to make it possible to use in other languages such as Rust. lyd_parent, lyd_child, and lyd_get_value are defined as static inline and is difficult for tools to wrap them.
4a7f195
to
89dde2f
Compare
How come? These functions are defined in a public header, so they should be usable just fine, AFAICT. What is the exact problem that you're solving with this patch, and what error message in which scenario are you getting without this patch? |
If we have to use these functions in another language such as Rust, tools such as rust-bindgen, do not easily generate wrappers for them. |
That's been supported since 2022, rust-lang/rust-bindgen#2335 |
We need certain functions to be exposed via a public API to make it
possible to use in other languages such as Rust.
lyd_parent, lyd_child, and lyd_get_value are defined as static inline
and is difficult for tools to wrap them.